<template>
    <van-rate v-model="curValue" :disabled="disabled"/>
</template>

<script lang="ts">
import { Vue, Component, Prop, Provide, Emit, Watch } from 'vue-property-decorator';
@Component({
    components: {
    }
})
export default class AppRate extends Vue {       
        /**
         * 评分值
         *
         * @type {string}
         * @memberof AppRate
         */
        @Prop() public value?: string;
        
        /**
         * 获取输入的Value值
         *
         * @type {string}
         * @memberof AppRate
         */
		get curValue(){
			return this.value;
		}

		/**
         * 根据curValue变化抛出事件change
         *
         * @type {string}
         * @memberof AppRate
         */
		set curValue(val:any){
			this.$emit('change',val);
        }
        

		/**
         * 禁用
         *
         * @type {boolean}
         * @memberof AppRate
         */
		@Prop() public disabled?: boolean;

}
</script>
<style lang="less">

</style>